#ifndef TERRAIN_CLUMP_H
#define TERRAIN_CLUMP_H
#include <string>
#include <vector>
#include "glee/GLee.h"
#include "targa.h"
#include "geom.h"
#include "glslshader.h"
class Terrain;
class TerrainClump
{
public:
	TerrainClump(Terrain* terrain, int index, int x, int z, int w, int h);
	~TerrainClump(void);

	void generateIndices(int width, int numClumps);
	std::vector<GLuint> getIndices() { return m_indices; }
	GLuint getIndexBuffer() { return m_indexBuffer; }
	void generateBoundingVolume(std::vector<Vertex> verts);

	void render();

	Vertex center;
	float radius;
private:
	Terrain* m_terrain;
	int m_index;

	int m_clumpX;
	int m_clumpZ;

	int m_width;
	int m_height;

	float minX;
	float maxX;
	float minY;
	float maxY;
	float minZ;
	float maxZ;


    GLuint m_indexBuffer;
    std::vector<GLuint> m_indices;
};

#endif

